<!--
  v-bind 经常用
 -->

<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>

<body>

  <div id="app">
    <!-- 错误的写法，这里不可以使用Mustache语法 -->
    <img src="{{imgURL}} alt=' ' " />

    <br />

    <!-- 正确的写法 -->
    <!-- <img v-bind:src='imgURL' alt=' ' /> -->
    <!-- <img :src='imgURL' alt=' ' /> -->

    <!-- <img v-bind:[key]='imgURL' alt=' ' /> -->
    <!-- <img :src="'/path/to/images' + imgURL" alt=' ' /> -->
  </div>

  <script src="../../js/vue.js"></script>
  <script>
    let img_url = 'http://n.sinaimg.cn/photo/transform/700/w1000h500/20200323/1ecb-ireifzi0941036.jpg';

    const app = new Vue({
      el: '#app',
      data: {
        imgURL: img_url
      },
    })
  </script>
</body>

</html>